package org.dtrd.modules.record.entity.bean;

import lombok.Data;
import org.dtrd.config.system.Constant;

/**
 * @author 萧
 * @date:2021-10-10 10:08 上午
 **/
@Data
public class AbnormalSugarRecordBean {

    private String timeType;
    private String signinTime;
    private Integer patientId;
    private Float sugarValue;
    private Float waveValue;
    private String message;

    public AbnormalSugarRecordBean init(CheckinRecord checkinRecord) {
        timeType = Constant.SugarRecordType.valueOf(checkinRecord.getSubType()).getName();
        signinTime = checkinRecord.getRecordTime();
        patientId = checkinRecord.getPatientId();
        sugarValue = checkinRecord.getSugarValue();
        waveValue = null;
        return this;
    }
}
